//
//  tableViewModel.m
//  MyProject
//
//  Created by dllo on 15/11/3.
//  Copyright (c) 2015年 蓝鸥0825. All rights reserved.
//

#import "tableViewModel.h"

@implementation tableViewModel

- (id)initWithImage:(NSString *)image title:(NSString *)title price:(NSString *)price market_price:(NSString *)market_price{
    
    self = [super init];
    if (self) {
        self.image = image;
        self.title = title;
        self.price = price;
        self.market_price = market_price;
    }
    return self;
}




- (void)encodeWithCoder:(NSCoder *)aCoder{
    
    [aCoder encodeObject:self.image forKey:@"image"];
    [aCoder encodeObject:self.title forKey:@"title"];
    [aCoder encodeObject:self.price forKey:@"price"];
    [aCoder encodeObject:self.market_price forKey:@"market_price"];
    
}



- (id)initWithCoder:(NSCoder *)aDecoder{
 
    self = [super init];
    if (self) {
        self.image = [aDecoder decodeObjectForKey:@"image"];
        self.title = [aDecoder decodeObjectForKey:@"title"];
        self.price = [aDecoder decodeObjectForKey:@"price"];
        self.market_price = [aDecoder decodeObjectForKey:@"market_price"];
    }
    return self;
    
    
}




@end
